package com.atguigu.service.impl;

import com.atguigu.dao.EmployeeDao;
import com.atguigu.pojo.Employee;
import com.atguigu.service.EmployeeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @version 1.0
 * @Author 马冰
 * @Date 2024/12/23 20:42
 * @注释
 */
@Service
public class EmployeeServiceImpl implements EmployeeService {

    @Autowired
    private EmployeeDao employeeDao;

    @Override
    public List<Employee> findAllService() {
        return employeeDao.findAllDao();
    }

    @Override
    public Employee findEmployeeById(Integer id) {
        return employeeDao.findEmployeeById(id);
    }

    @Override
    public String addEmployee(Employee employee) {
        return employeeDao.addEmployee(employee);
    }

    @Override
    public String updateEmployee(Employee employee) {
        return employeeDao.updateEmployee(employee);
    }

    @Override
    public String deleteEmployee(Integer id) {
        return employeeDao.deleteEmployee(id);
    }
}
